import request from "@/utils/request"

// 查询工段列表
export function listWorkshopSection(query) {
	return request({
		url: "/erp/workshopSection/list",
		method: "get",
		params: query
	})
}

// 查询工段详细
export function getWorkshopSection(id) {
	return request({
		url: "/erp/workshopSection/" + id,
		method: "get"
	})
}

// 新增工段
export function addWorkshopSection(data) {
	return request({
		url: "/erp/workshopSection",
		method: "post",
		data: data
	})
}

// 修改工段
export function updateWorkshopSection(data) {
	return request({
		url: "/erp/workshopSection",
		method: "put",
		data: data
	})
}

// 删除工段
export function delWorkshopSection(id) {
	return request({
		url: "/erp/workshopSection/" + id,
		method: "delete"
	})
}

// 新增工段人员
export function workshopSectionUser(data) {
	return request({
		url: "/erp/workshopSectionUser",
		method: "post",
		data
	})
}
// 工段人员列表
export function workUserlist(params) {
	return request({
		url: "/erp/workshopSectionUser/list",
		method: "get",
		params
	})
}

// 查询用户列表
export function listUser(query) {
	return request({
		url: "/erp/selectDown/userDown1",
		method: "get",
		params: query
	})
}
